﻿using System.ComponentModel.DataAnnotations;

namespace HengTong.Model.Request;

public class SendSmsCodeRequest
{
    [Required(ErrorMessage = "手机号不能为空")]
    [RegularExpression(@"^1\d{10}$", ErrorMessage = "手机号格式不正确")]
    public string Mobile { get; set; }

    /// <summary>
    /// 验证码类型：login-验证码登录、guestBind-游客绑定用户、changePassword-修改密码、changeMobile-修改手机号
    /// </summary>
    [Required(ErrorMessage = "验证码类型不能为空")]
    public string Type { get; set; }

    /// <summary>
    /// 原手机号，用于修改手机号和修改密码场景
    /// </summary>
    public string OldPhone { get; set; }
}